package point;
import java.lang.Math;
//
class Point {
    double x;
    double y;
    double z;

    public Point() {
        x = 0;
        y = 0;
        z = 0;
    }

    public Point(double x, double y, double z) {
        this.x = x;
        this.y = y;
        this.z = z;
    }

    public void setpoint(double x, double y, double z) {
        this.x = x;
        this.y = y;
        this.z = z;
    }

    public double getx() {
        return x;
    }

    public double gety() {
        return y;
    }

    public double getz() {
        return z;
    }

    public double distant(Point p) {
        double f=p.x * p.x + p.y * p.y + p.z * p.z;
        double d = Math.sqrt(f);
        System.out.println("d=" + d);
        return d;
    }
}

